:root {
    --bg: #0f172a;
    --panel: #111827;
    --text: #e5e7eb;
    --muted: #9ca3af;
    --primary: #22d3ee;
    --green: #22c55e;
    --red: #ef4444;
    --yellow: #eab308;
    --border: #1f2937;
}

* {
    box-sizing: border-box;
}

html,
body {
    height: 100%;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
}

.app-header {
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
}

.app-header h1 {
    margin: 0;
    font-size: 20px;
}

.container {
    padding: 16px;
    max-width: 1200px;
    margin: 0 auto;
}

.panel {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 16px;
}

.filters {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.filters input,
.filters select {
    background: #0b1220;
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 8px 10px;
}

.filters button {
    background: var(--primary);
    color: #001018;
    border: none;
    border-radius: 6px;
    padding: 8px 12px;
    cursor: pointer;
}

.filters .auto-refresh {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--muted);
}

.table-wrap {
    overflow: auto;
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 10px 12px;
    border-bottom: 1px solid var(--border);
    text-align: left;
}

.table th {
    color: var(--muted);
    font-weight: 600;
}

.table .mono {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 12px;
}

tr.status-running td {
    background: rgba(34, 211, 238, 0.06);
}

tr.status-success td {
    background: rgba(34, 197, 94, 0.06);
}

tr.status-failed td {
    background: rgba(239, 68, 68, 0.06);
}

.pagination {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-top: 8px;
    color: var(--muted);
}

.pagination button {
    background: #0b1220;
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 6px 10px;
    cursor: pointer;
}

.logs {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
    max-height: 420px;
    overflow: auto;
    padding-right: 4px;
}

.log-row {
    display: grid;
    grid-template-columns: 170px 90px 1fr 1fr;
    gap: 8px;
    align-items: baseline;
}

.log-time {
    color: var(--muted);
    font-size: 12px;
}

.log-level {
    font-weight: 700;
    font-size: 12px;
}

.log-level.lvl-info {
    color: var(--text);
}

.log-level.lvl-warn {
    color: var(--yellow);
}

.log-level.lvl-error {
    color: var(--red);
}

.log-message {
    white-space: pre-wrap;
}

.log-meta {
    color: var(--muted);
    font-size: 12px;
    white-space: pre-wrap;
}